﻿@model FILSTARTUPS_CMS.Models.Pages

@{
    ViewBag.Title = "Edit";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@section Pagename{
<h2>Edit <small>Page Information</small></h2>
}
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm("Edit", "Page", FormMethod.Post, new { @class = "form-stacked" }))
{
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Pages</legend>

        @Html.HiddenFor(model => model.pageidPK)

        <div class="editor-label">
            @Html.LabelFor(model => model.Pagetitle)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Pagetitle)
            @Html.ValidationMessageFor(model => model.Pagetitle)
        </div>

          <div class="editor-label">
            @Html.LabelFor(model => model.routingidFK)
        </div>
        <div class="editor-field">
            @Html.DropDownList("routingidFK", new SelectList(ViewData["routing"] as System.Collections.IEnumerable,
                                                    "routingidPK", "routingname"))
        </div>


        <div class="editor-label">
            @Html.LabelFor(model => model.Pagedescription)
        </div>
        <div class="editor-field">
            @Html.TextAreaFor(model => model.Pagedescription, new { @class = "ckeditor" })
            @Html.ValidationMessageFor(model => model.Pagedescription)
        </div>
        <br />
        <p>
            <input type="submit" value="Save" />
        </p>
    </fieldset>
}

<div>
    @Html.ActionLink("Back to List", "Index")
</div>
